//
import { createRouter, createWebHistory } from 'vue-router';
//引入组件
import News from '@/views/News'
import About from '@/views/About'

// 定义路由规则
const routes = [
    { path: '/', component: News },
    { path: '/about', component: About },
]

//创建路由对象
const router = createRouter({
    routes,
    history: createWebHistory()
})

export default router